diff --git a/docs/whats-new.md b/docs/whats-new.md index 96bcce0d4df..97e92cec550 100644 --- a/docs/whats-new.md +++ b/docs/whats-new.md @@ -11,8 +11,9 @@ of the [MetaMask developer page](https://metamask.io/developer/). ## July 2024 -- Documented [Celo WebSocket support](/services/reference/celo/). ([#1446](https://github.com/MetaMask/metamask-docs/pull/1446)) -- Documented [ZKsync Era WebSocket support](/services/reference/zksync). ([#1438](https://github.com/MetaMask/metamask-docs/pull/1438)) +- Documented [Binance Smart Chain](/services/reference/bnb-smart-chain/) support. ([#1458](https://github.com/MetaMask/metamask-docs/pull/1458)) +- Documented [Celo WebSocket](/services/reference/celo/) support. ([#1446](https://github.com/MetaMask/metamask-docs/pull/1446)) +- Documented [ZKsync Era WebSocket](/services/reference/zksync) support. ([#1438](https://github.com/MetaMask/metamask-docs/pull/1438)) - Documented support for the [ZKsync Era network API service](/services/reference/zksync). ([#1372](https://github.com/MetaMask/metamask-docs/pull/1372)) - Added [Services](/services) and [Developer tools](/developer-tools) to MetaMask documentation. ([#1325](https://github.com/MetaMask/metamask-docs/pull/1325)) diff --git a/services/get-started/endpoints.md b/services/get-started/endpoints.md index 1df33903ee6..5d0ef3d5db5 100644 --- a/services/get-started/endpoints.md +++ b/services/get-started/endpoints.md @@ -47,6 +47,14 @@ request to `support@infura.io` and we will assess if your request can be accommo | Mainnet | JSON-RPC over HTTPS | `https://blast-mainnet.infura.io/v3/` | | Testnet (Sepolia) | JSON-RPC over HTTPS | `https://blast-sepolia.infura.io/v3/` | +## Binance Smart Chain + +| Network | Transport type | URL | +|-------------------|-------------------------|-----------------------------------------------| +| Mainnet | JSON-RPC over HTTPS | `https://bsc-mainnet.infura.io/v3/` | +| Mainnet | JSON-RPC over WebSocket | `wss://bsc-mainnet.infura.io/ws/v3/` | +| Testnet (Sepolia) | JSON-RPC over HTTPS | `https://bsc-testnet.infura.io/v3/` | + ## Celo | Network | Description | URL | diff --git a/services/reference/blast/quickstart.md b/services/reference/blast/quickstart.md index 7859f43bb96..308715becb2 100644 --- a/services/reference/blast/quickstart.md +++ b/services/reference/blast/quickstart.md @@ -187,8 +187,7 @@ In these examples, you'll use [NPM](https://docs.npmjs.com/downloading-and-insta ## Next steps -Now that you have successfully made a call to the Blast network, you can explore more functionalities and APIs provided -by Infura. Here are some suggestions: +Now that you have successfully made a call to the Blast network, you can explore more functionalities and APIs. Here are some suggestions: - **Explore other Blast APIs**: Infura supports a wide range of APIs. You can find more information in the [JSON-RPC API method documentation](json-rpc-methods/index.md). diff --git a/services/reference/bnb-smart-chain/index.md b/services/reference/bnb-smart-chain/index.md new file mode 100644 index 00000000000..00e4edbbf84 --- /dev/null +++ b/services/reference/bnb-smart-chain/index.md @@ -0,0 +1,63 @@ +--- +description: BNB Smart Chain network documentation +--- + +import CardList from "@site/src/components/CardList" + +# BNB Smart Chain + +:::note Decentralized Infrastructure Network (DIN) + +BNB Smart Chain (BSC) is supported through the [DIN](https://www.infura.io/solutions/decentralized-infrastructure-service) service, +meaning calls to the network are routed to [partner infrastructure providers](#partners-and-privacy-policies). + +Infura provides Open Beta access to BSC. During this period, there might be feature limitations. +Performance issues are not expected, but they are possible as we optimize and stabilize the service. + +Currently, only near head requests (the last 128 blocks) are supported in the +BSC service. Archive requests are not currently supported. Be aware of this limitation when making calls +to API calls to methods such as [`eth_getStorageAt`](./json-rpc-methods/eth_getstorageat.mdx), +[`eth_getTransactionReceipt`](./json-rpc-methods/eth_gettransactionreceipt.mdx), and +[`eth_getTransactionByHash`](./json-rpc-methods/eth_gettransactionbyhash.mdx). + +::: + +BNB Smart Chain is a self-sovereign blockchain with elected validators running a Proof of Staked +Authority (PoSA) consensus protocol. It is EVM-compatible and supports existing Ethereum tooling. + +:::info See also + +For more information, refer to the official [BSC documentation](https://docs.bnbchain.org/bnb-smart-chain/). + +::: + +Select an option below to get started with the BSC network. + + + +## Partners and privacy policies + +The following partners provide access to the BSC network: + +- Chainstack ([Terms of Service](https://chainstack.com/tos/), [Privacy Policy](https://chainstack.com/privacy/)) +- Infstones ([Privacy Policy](https://infstones.com/terms/privacy-notice)) +- Liquify ([Privacy Policy](https://www.liquify.com/Liquify_RPC_PP.pdf)) + \ No newline at end of file diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_accounts-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_accounts-request.mdx new file mode 100644 index 00000000000..f5761ee027a --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_accounts-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_accounts", "params": [], "id":1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_accounts", "params": [], "id":1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_blocknumber-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_blocknumber-request.mdx new file mode 100644 index 00000000000..9dadf21a5c2 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_blocknumber-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_blockNumber", "params": [], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_blockNumber", "params": [], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_call-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_call-request.mdx new file mode 100644 index 00000000000..78a56c38470 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_call-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_call", "params": [{"from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155", "to": "0xd46e8dd67c5d32be8058bb8eb970870f07244567", "gas": "0x76c0", "gasPrice": "0x9184e72a000", "value": "0x9184e72a", "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"}, "latest"], "id":1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_call", "params": [{"from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155", "to": "0xd46e8dd67c5d32be8058bb8eb970870f07244567", "gas": "0x76c0", "gasPrice": "0x9184e72a000", "value": "0x9184e72a", "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"}, "latest"], "id":1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_chainid-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_chainid-request.mdx new file mode 100644 index 00000000000..46b56406fdc --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_chainid-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_chainId", "params": [], "id":1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_chainId", "params": [], "id":1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_estimategas-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_estimategas-request.mdx new file mode 100644 index 00000000000..797b16b5b73 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_estimategas-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_estimateGas", "params": [{"from": "0x9cE564c7d09f88E7d8233Cdd3A4d7AC42aBFf3aC", "to": "0xd46e8dd67c5d32be8058bb8eb970870f07244567", "value": "0x9184e72a"}], "id":1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_estimateGas", "params": [{"from": "0x9cE564c7d09f88E7d8233Cdd3A4d7AC42aBFf3aC", "to": "0xd46e8dd67c5d32be8058bb8eb970870f07244567", "value": "0x9184e72a"}], "id":1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gasprice-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gasprice-request.mdx new file mode 100644 index 00000000000..348926f73fb --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gasprice-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_gasPrice", "params": [], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method":"eth_gasPrice", "params": [], "id":1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getbalance-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getbalance-request.mdx new file mode 100644 index 00000000000..19d13d12514 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getbalance-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_getBalance", "params": ["0xc94770007dda54cF92009BFF0dE90c06F603a09f", "latest"], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_getBalance", "params": ["0xc94770007dda54cF92009BFF0dE90c06F603a09f", "latest"], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getblockbyhash-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getblockbyhash-request.mdx new file mode 100644 index 00000000000..c67ae8e6f33 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getblockbyhash-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method":"eth_getBlockByHash", "params": ["0xb3b20624f8f0f86eb50dd04688409e5cea4bd02d700bf6e79e9384d47d6a5a35", false], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method":"eth_getBlockByHash", "params": ["0xb3b20624f8f0f86eb50dd04688409e5cea4bd02d700bf6e79e9384d47d6a5a35", false], "id":1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getblockbynumber-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getblockbynumber-request.mdx new file mode 100644 index 00000000000..82af1d63b1c --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getblockbynumber-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_getBlockByNumber", "params":["0x5BAD55", false], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_getBlockByNumber", "params":["0x5BAD55", false], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getblockreceipts-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getblockreceipts-request.mdx new file mode 100644 index 00000000000..7a9ffcc4bfe --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getblockreceipts-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_getBlockReceipts", "params": ["latest"], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_getBlockReceipts", "params": ["latest"], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getblocktransactioncountbyhash-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getblocktransactioncountbyhash-request.mdx new file mode 100644 index 00000000000..b1edeabb843 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getblocktransactioncountbyhash-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_getBlockTransactionCountByHash", "params": ["0xb3b20624f8f0f86eb50dd04688409e5cea4bd02d700bf6e79e9384d47d6a5a35"], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_getBlockTransactionCountByHash", "params": ["0xb3b20624f8f0f86eb50dd04688409e5cea4bd02d700bf6e79e9384d47d6a5a35"], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getblocktransactioncountbynumber-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getblocktransactioncountbynumber-request.mdx new file mode 100644 index 00000000000..f81de3cd152 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getblocktransactioncountbynumber-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_getBlockTransactionCountByNumber", "params": ["latest"], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_getBlockTransactionCountByNumber", "params": ["latest"], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getcode-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getcode-request.mdx new file mode 100644 index 00000000000..b2d499e898d --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getcode-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method":"eth_getCode", "params": ["0x06012c8cf97bead5deae237070f9587f8e7a266d", "0x65a8db"], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method":"eth_getCode", "params": ["0x06012c8cf97bead5deae237070f9587f8e7a266d", "0x65a8db"], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getlogs-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getlogs-request.mdx new file mode 100644 index 00000000000..b93224df3f5 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getlogs-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_getLogs", "params": [{"blockHash": "0x7c5a35e9cb3e8ae0e221ab470abae9d446c3a5626ce6689fc777dcffcab52c70", "topics":["0x241ea03ca20251805084d27d4440371c34a0b85ff108f6bb5611248f73818b80"]}], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_getLogs", "params": [{"blockHash": "0x7c5a35e9cb3e8ae0e221ab470abae9d446c3a5626ce6689fc777dcffcab52c70", "topics":["0x241ea03ca20251805084d27d4440371c34a0b85ff108f6bb5611248f73818b80"]}], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getproof-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getproof-request.mdx new file mode 100644 index 00000000000..24c87de4572 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getproof-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_getProof", "id": 1, "params": ["0x7F0d15C7FAae65896648C8273B6d7E43f58Fa842", ["0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421"], "latest"]}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_getProof", "id": 1, "params": ["0x7F0d15C7FAae65896648C8273B6d7E43f58Fa842", ["0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421"], "latest"]}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getstorageat-description.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getstorageat-description.mdx new file mode 100644 index 00000000000..b62112535ac --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getstorageat-description.mdx @@ -0,0 +1,8 @@ +Returns the value from a storage position at a given address. + +:::info + +Currently, the Binance Smart Chain service supports only near head requests (the latest 128 blocks). +Archive requests are not available at this time. + +::: diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getstorageat-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getstorageat-request.mdx new file mode 100644 index 00000000000..933f6c5566a --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getstorageat-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_getStorageAt", "params": ["0x295a70b2de5e3953354a6a8344e616ed314d7251", "0x6661e9d6d8b923d5bbaab1b96e1dd51ff6ea2a93520fdc9eb75d059238b8c5e9", "0x65a8db"], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_getStorageAt", "params": ["0x295a70b2de5e3953354a6a8344e616ed314d7251", "0x6661e9d6d8b923d5bbaab1b96e1dd51ff6ea2a93520fdc9eb75d059238b8c5e9", "0x65a8db"], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactionbyblockhashandindex-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactionbyblockhashandindex-request.mdx new file mode 100644 index 00000000000..0c1d73c1af6 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactionbyblockhashandindex-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_getTransactionByBlockHashAndIndex", "params": ["0xb3b20624f8f0f86eb50dd04688409e5cea4bd02d700bf6e79e9384d47d6a5a35", "0x0"], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_getTransactionByBlockHashAndIndex", "params": ["0xb3b20624f8f0f86eb50dd04688409e5cea4bd02d700bf6e79e9384d47d6a5a35", "0x0"], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactionbyblocknumberandindex-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactionbyblocknumberandindex-request.mdx new file mode 100644 index 00000000000..ccd4d9b57fd --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactionbyblocknumberandindex-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_getTransactionByBlockNumberAndIndex", "params": ["0x5BAD55", "0x0"], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_getTransactionByBlockNumberAndIndex", "params": ["0x5BAD55", "0x0"], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactionbyhash-description.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactionbyhash-description.mdx new file mode 100644 index 00000000000..7d1167671ba --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactionbyhash-description.mdx @@ -0,0 +1,8 @@ +Returns information about a transaction for a given hash. + +:::info + +Currently, the Binance Smart Chain service supports only near head requests (the latest 128 blocks). +Archive requests are not available at this time. + +::: \ No newline at end of file diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactionbyhash-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactionbyhash-request.mdx new file mode 100644 index 00000000000..a85c9467b9d --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactionbyhash-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_getTransactionByHash", "params": ["0xbb3a336e3f823ec18197f1e13ee875700f08f03e2cab75f0d0b118dabb44cba0"], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_getTransactionByHash", "params": ["0xbb3a336e3f823ec18197f1e13ee875700f08f03e2cab75f0d0b118dabb44cba0"], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactioncount-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactioncount-request.mdx new file mode 100644 index 00000000000..b99dc610cd6 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactioncount-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_getTransactionCount", "params": ["0xc94770007dda54cF92009BFF0dE90c06F603a09f", "0x5bad55"], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_getTransactionCount", "params": ["0xc94770007dda54cF92009BFF0dE90c06F603a09f", "0x5bad55"], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactionreceipt-description.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactionreceipt-description.mdx new file mode 100644 index 00000000000..16ee0fbab3b --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactionreceipt-description.mdx @@ -0,0 +1,8 @@ +Returns the receipt of a transaction given transaction hash. Note that the receipt is not available for pending transactions. + +:::info + +Currently, the Binance Smart Chain service supports only near head requests (the latest 128 blocks). +Archive requests are not available at this time. + +::: \ No newline at end of file diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactionreceipt-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactionreceipt-request.mdx new file mode 100644 index 00000000000..e63bedb3073 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_gettransactionreceipt-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_getTransactionReceipt", "params": ["0xbb3a336e3f823ec18197f1e13ee875700f08f03e2cab75f0d0b118dabb44cba0"], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_getTransactionReceipt", "params": ["0xbb3a336e3f823ec18197f1e13ee875700f08f03e2cab75f0d0b118dabb44cba0"], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getunclebyblockhashandindex-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getunclebyblockhashandindex-request.mdx new file mode 100644 index 00000000000..370077f62e2 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getunclebyblockhashandindex-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_getUncleByBlockHashAndIndex", "params": ["0xb3b20624f8f0f86eb50dd04688409e5cea4bd02d700bf6e79e9384d47d6a5a35", "0x0"], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_getUncleByBlockHashAndIndex", "params": ["0xb3b20624f8f0f86eb50dd04688409e5cea4bd02d700bf6e79e9384d47d6a5a35", "0x0"], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getunclebyblocknumberandindex-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getunclebyblocknumberandindex-request.mdx new file mode 100644 index 00000000000..1cd5263663b --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getunclebyblocknumberandindex-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_getUncleByBlockNumberAndIndex", "params": ["0x29c", "0x0"], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_getUncleByBlockNumberAndIndex", "params": ["0x29c", "0x0"], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getunclecountbyblockhash-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getunclecountbyblockhash-request.mdx new file mode 100644 index 00000000000..d7a3d88230c --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getunclecountbyblockhash-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_getUncleCountByBlockHash", "params": ["0xb3b20624f8f0f86eb50dd04688409e5cea4bd02d700bf6e79e9384d47d6a5a35"], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_getUncleCountByBlockHash", "params": ["0xb3b20624f8f0f86eb50dd04688409e5cea4bd02d700bf6e79e9384d47d6a5a35"], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getunclecountbyblocknumber-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getunclecountbyblocknumber-request.mdx new file mode 100644 index 00000000000..7d542e72424 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_getunclecountbyblocknumber-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_getUncleCountByBlockNumber", "params": ["0x5bad55"], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_getUncleCountByBlockNumber", "params": ["0x5bad55"], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_maxpriorityfeepergas-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_maxpriorityfeepergas-request.mdx new file mode 100644 index 00000000000..a5bee7642e6 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_maxpriorityfeepergas-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_maxPriorityFeePerGas", "params": [], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/d23391e03c6d40738530a1b4b679e66e -x '{"jsonrpc": "2.0", "method": "eth_maxPriorityFeePerGas", "params": [], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_protocolversion-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_protocolversion-request.mdx new file mode 100644 index 00000000000..14c5716612e --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_protocolversion-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_protocolVersion", "params": [], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_protocolVersion", "params": [], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_sendrawtransaction-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_sendrawtransaction-request.mdx new file mode 100644 index 00000000000..b2c6757e652 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_sendrawtransaction-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_sendRawTransaction", "params": ["0xf869018203e882520894f17f52151ebef6c7334fad080c5704d77216b732881bc16d674ec80000801ba02da1c48b670996dcb1f447ef9ef00b33033c48a4fe938f420bec3e56bfd24071a062e0aa78a81bf0290afbc3a9d8e9a068e6d74caa66c5e0fa8a46deaae96b0833"], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_sendRawTransaction", "params": ["0xf869018203e882520894f17f52151ebef6c7334fad080c5704d77216b732881bc16d674ec80000801ba02da1c48b670996dcb1f447ef9ef00b33033c48a4fe938f420bec3e56bfd24071a062e0aa78a81bf0290afbc3a9d8e9a068e6d74caa66c5e0fa8a46deaae96b0833"], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_submitwork-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_submitwork-request.mdx new file mode 100644 index 00000000000..d8c8f421de7 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_submitwork-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_submitWork", "params": ["0x0000000000000001", "0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef", "0xD1FE5700000000000000000000000000D1FE5700000000000000000000000000"], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method":"eth_submitWork", "params": ["0x0000000000000001", "0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef", "0xD1FE5700000000000000000000000000D1FE5700000000000000000000000000"], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_eth_syncing-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_syncing-request.mdx new file mode 100644 index 00000000000..80dad26f348 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_eth_syncing-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method":"eth_syncing", "params": [], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method":"eth_syncing", "params": [], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_net_listening-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_net_listening-request.mdx new file mode 100644 index 00000000000..d6967bc69c4 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_net_listening-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0","method": "net_listening", "params": [], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0","method": "net_listening", "params": [], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_net_peercount-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_net_peercount-request.mdx new file mode 100644 index 00000000000..dbd714b19f0 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_net_peercount-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "net_peerCount", "params": [], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "net_peerCount", "params": [], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_net_version-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_net_version-request.mdx new file mode 100644 index 00000000000..717c66f9f1d --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_net_version-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "net_version", "params": [], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "net_version", "params": [], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/_web3_clientversion-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/_web3_clientversion-request.mdx new file mode 100644 index 00000000000..6d1616ca811 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/_web3_clientversion-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "web3_clientVersion", "params": [], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "web3_clientVersion", "params": [], "id": 1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_accounts.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_accounts.mdx new file mode 100644 index 00000000000..0c5088b9560 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_accounts.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_accounts" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_accounts-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_accounts-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_accounts-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_accounts-example.mdx"; + + + +### Request + +import Request from "./_eth_accounts-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_accounts-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_blocknumber.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_blocknumber.mdx new file mode 100644 index 00000000000..f10357f32e3 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_blocknumber.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_blockNumber" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_blocknumber-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_blocknumber-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_blocknumber-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_blocknumber-example.mdx"; + + + +### Request + +import Request from "./_eth_blocknumber-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_blocknumber-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_call.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_call.mdx new file mode 100644 index 00000000000..d4c9cf9a095 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_call.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_call" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_call-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_call-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_call-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_call-example.mdx"; + + + +### Request + +import Request from "./_eth_call-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_call-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_chainid.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_chainid.mdx new file mode 100644 index 00000000000..c385efc1ed1 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_chainid.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_chainId" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_chainid-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_chainid-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_chainid-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_chainid-example.mdx"; + + + +### Request + +import Request from "./_eth_chainid-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_chainid-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_estimategas.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_estimategas.mdx new file mode 100644 index 00000000000..fcf752d84b3 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_estimategas.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_estimateGas" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_estimategas-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_estimategas-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_estimategas-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_estimategas-example.mdx"; + + + +### Request + +import Request from "./_eth_estimategas-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_estimategas-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_gasprice.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_gasprice.mdx new file mode 100644 index 00000000000..f5ce241a9ae --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_gasprice.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_gasPrice" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_gasprice-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_gasprice-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_gasprice-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_gasprice-example.mdx"; + + + +### Request + +import Request from "./_eth_gasprice-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_gasprice-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_getbalance.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getbalance.mdx new file mode 100644 index 00000000000..814f2e5a8bf --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getbalance.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getBalance" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_getbalance-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_getbalance-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_getbalance-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_getbalance-example.mdx"; + + + +### Request + +import Request from "./_eth_getbalance-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_getbalance-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_getblockbyhash.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getblockbyhash.mdx new file mode 100644 index 00000000000..435c47dd6d2 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getblockbyhash.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getBlockByHash" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_getblockbyhash-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_getblockbyhash-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_getblockbyhash-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_getblockbyhash-example.mdx"; + + + +### Request + +import Request from "./_eth_getblockbyhash-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_getblockbyhash-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_getblockbynumber.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getblockbynumber.mdx new file mode 100644 index 00000000000..2a4855cfb5d --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getblockbynumber.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getBlockByNumber" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_getblockbynumber-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_getblockbynumber-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_getblockbynumber-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_getblockbynumber-example.mdx"; + + + +### Request + +import Request from "./_eth_getblockbynumber-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_getblockbynumber-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_getblockreceipts.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getblockreceipts.mdx new file mode 100644 index 00000000000..80a91784b1a --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getblockreceipts.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getBlockReceipts" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_getblockreceipts-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_getblockreceipts-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_getblockreceipts-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_getblockreceipts-example.mdx"; + + + +### Request + +import Request from "./_eth_getblockreceipts-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_getblockreceipts-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_getblocktransactioncountbyhash.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getblocktransactioncountbyhash.mdx new file mode 100644 index 00000000000..30ece4724b3 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getblocktransactioncountbyhash.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getBlockTransactionCountByHash" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_getblocktransactioncountbyhash-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_getblocktransactioncountbyhash-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_getblocktransactioncountbyhash-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_getblocktransactioncountbyhash-example.mdx"; + + + +### Request + +import Request from "./_eth_getblocktransactioncountbyhash-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_getblocktransactioncountbyhash-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_getblocktransactioncountbynumber.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getblocktransactioncountbynumber.mdx new file mode 100644 index 00000000000..2cc69dd469e --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getblocktransactioncountbynumber.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getBlockTransactionCountByNumber" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_getblocktransactioncountbynumber-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_getblocktransactioncountbynumber-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_getblocktransactioncountbynumber-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_getblocktransactioncountbynumber-example.mdx"; + + + +### Request + +import Request from "./_eth_getblocktransactioncountbynumber-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_getblocktransactioncountbynumber-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_getcode.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getcode.mdx new file mode 100644 index 00000000000..906f21a6d9e --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getcode.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getCode" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_getcode-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_getcode-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_getcode-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_getcode-example.mdx"; + + + +### Request + +import Request from "./_eth_getcode-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_getcode-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_getlogs.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getlogs.mdx new file mode 100644 index 00000000000..860d7568027 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getlogs.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getLogs" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_getlogs-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_getlogs-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_getlogs-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_getlogs-example.mdx"; + + + +### Request + +import Request from "./_eth_getlogs-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_getlogs-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_getproof.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getproof.mdx new file mode 100644 index 00000000000..c80a278d835 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getproof.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getProof" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_getproof-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_getproof-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_getproof-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_getproof-example.mdx"; + + + +### Request + +import Request from "./_eth_getproof-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_getproof-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_getstorageat.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getstorageat.mdx new file mode 100644 index 00000000000..e55efec5a0c --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getstorageat.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getStorageAt" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "./_eth_getstorageat-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_getstorageat-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_getstorageat-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_getstorageat-example.mdx"; + + + +### Request + +import Request from "./_eth_getstorageat-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_getstorageat-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_gettransactionbyblockhashandindex.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_gettransactionbyblockhashandindex.mdx new file mode 100644 index 00000000000..0a240af37d2 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_gettransactionbyblockhashandindex.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getTransactionByBlockHashAndIndex" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_gettransactionbyblockhashandindex-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_gettransactionbyblockhashandindex-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_gettransactionbyblockhashandindex-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_gettransactionbyblockhashandindex-example.mdx"; + + + +### Request + +import Request from "./_eth_gettransactionbyblockhashandindex-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_gettransactionbyblockhashandindex-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_gettransactionbyblocknumberandindex.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_gettransactionbyblocknumberandindex.mdx new file mode 100644 index 00000000000..e31108b277a --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_gettransactionbyblocknumberandindex.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getTransactionByBlockNumberAndIndex" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_gettransactionbyblocknumberandindex-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_gettransactionbyblocknumberandindex-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_gettransactionbyblocknumberandindex-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_gettransactionbyblocknumberandindex-example.mdx"; + + + +### Request + +import Request from "./_eth_gettransactionbyblocknumberandindex-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_gettransactionbyblocknumberandindex-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_gettransactionbyhash.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_gettransactionbyhash.mdx new file mode 100644 index 00000000000..38ff25005b8 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_gettransactionbyhash.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getTransactionByHash" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "./_eth_gettransactionbyhash-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_gettransactionbyhash-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_gettransactionbyhash-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_gettransactionbyhash-example.mdx"; + + + +### Request + +import Request from "./_eth_gettransactionbyhash-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_gettransactionbyhash-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_gettransactioncount.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_gettransactioncount.mdx new file mode 100644 index 00000000000..28ec372d1e1 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_gettransactioncount.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getTransactionCount" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_gettransactioncount-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_gettransactioncount-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_gettransactioncount-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_gettransactioncount-example.mdx"; + + + +### Request + +import Request from "./_eth_gettransactioncount-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_gettransactioncount-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_gettransactionreceipt.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_gettransactionreceipt.mdx new file mode 100644 index 00000000000..2aba9413dba --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_gettransactionreceipt.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getTransactionReceipt" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "./_eth_gettransactionreceipt-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_gettransactionreceipt-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_gettransactionreceipt-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_gettransactionreceipt-example.mdx"; + + + +### Request + +import Request from "./_eth_gettransactionreceipt-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_gettransactionreceipt-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_getunclebyblockhashandindex.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getunclebyblockhashandindex.mdx new file mode 100644 index 00000000000..dda3bcea3a6 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getunclebyblockhashandindex.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getUncleByBlockHashAndIndex" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_getunclebyblockhashandindex-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_getunclebyblockhashandindex-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_getunclebyblockhashandindex-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_getunclebyblockhashandindex-example.mdx"; + + + +### Request + +import Request from "./_eth_getunclebyblockhashandindex-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_getunclebyblockhashandindex-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_getunclebyblocknumberandindex.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getunclebyblocknumberandindex.mdx new file mode 100644 index 00000000000..6575fe4d2c4 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getunclebyblocknumberandindex.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getUncleByBlockNumberAndIndex" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_getunclebyblocknumberandindex-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_getunclebyblocknumberandindex-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_getunclebyblocknumberandindex-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_getunclebyblocknumberandindex-example.mdx"; + + + +### Request + +import Request from "./_eth_getunclebyblocknumberandindex-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_getunclebyblocknumberandindex-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_getunclecountbyblockhash.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getunclecountbyblockhash.mdx new file mode 100644 index 00000000000..51a8d4b79c5 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getunclecountbyblockhash.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getUncleCountByBlockHash" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_getunclecountbyblockhash-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_getunclecountbyblockhash-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_getunclecountbyblockhash-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_getunclecountbyblockhash-example.mdx"; + + + +### Request + +import Request from "./_eth_getunclecountbyblockhash-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_getunclecountbyblockhash-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_getunclecountbyblocknumber.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getunclecountbyblocknumber.mdx new file mode 100644 index 00000000000..6b5a5f068ae --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_getunclecountbyblocknumber.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getUncleCountByBlockNumber" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_getunclecountbyblocknumber-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_getunclecountbyblocknumber-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_getunclecountbyblocknumber-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_getunclecountbyblocknumber-example.mdx"; + + + +### Request + +import Request from "./_eth_getunclecountbyblocknumber-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_getunclecountbyblocknumber-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_maxpriorityfeepergas.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_maxpriorityfeepergas.mdx new file mode 100644 index 00000000000..89d1421df00 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_maxpriorityfeepergas.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_maxPriorityFeePerGas" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_maxpriorityfeepergas-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_maxpriorityfeepergas-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_maxpriorityfeepergas-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_maxpriorityfeepergas-example.mdx"; + + + +### Request + +import Request from "./_eth_maxpriorityfeepergas-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_maxpriorityfeepergas-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_protocolversion.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_protocolversion.mdx new file mode 100644 index 00000000000..632a6b6cefd --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_protocolversion.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_protocolVersion" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_protocolversion-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_protocolversion-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_protocolversion-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_protocolversion-example.mdx"; + + + +### Request + +import Request from "./_eth_protocolversion-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_protocolversion-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_sendrawtransaction.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_sendrawtransaction.mdx new file mode 100644 index 00000000000..007139c8a82 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_sendrawtransaction.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_sendRawTransaction" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_sendrawtransaction-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_sendrawtransaction-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_sendrawtransaction-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_sendrawtransaction-example.mdx"; + + + +### Request + +import Request from "./_eth_sendrawtransaction-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_sendrawtransaction-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_sendtransaction.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_sendtransaction.mdx new file mode 100644 index 00000000000..915363a6184 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_sendtransaction.mdx @@ -0,0 +1,11 @@ +--- +title: "eth_sendTransaction" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_sendtransaction-description.mdx"; + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_submitwork.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_submitwork.mdx new file mode 100644 index 00000000000..4acde46ee9f --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_submitwork.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_submitWork" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_submitwork-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_submitwork-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_submitwork-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_submitwork-example.mdx"; + + + +### Request + +import Request from "./_eth_submitwork-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_submitwork-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/eth_syncing.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/eth_syncing.mdx new file mode 100644 index 00000000000..4dd0c0a0803 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/eth_syncing.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_syncing" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_eth_syncing-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_eth_syncing-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_eth_syncing-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_eth_syncing-example.mdx"; + + + +### Request + +import Request from "./_eth_syncing-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_eth_syncing-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_getfilterchanges-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_getfilterchanges-request.mdx new file mode 100644 index 00000000000..958c04cc2bb --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_getfilterchanges-request.mdx @@ -0,0 +1,23 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method":"eth_getFilterChanges", "params":["0x10ff0bfbedb01f0dbd4106d14eb719ec38b6eb5b821c"], "id":1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method":"eth_getFilterChanges", "params":["0x10ff0bfbedb01f0dbd4106d14eb719ec38b6eb5b821c"], "id":1}' +``` + + + \ No newline at end of file diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_getfilterlogs-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_getfilterlogs-request.mdx new file mode 100644 index 00000000000..88c54872049 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_getfilterlogs-request.mdx @@ -0,0 +1,23 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_getFilterLogs", "params":["0x10ff0bfbedb01f0dbd4106d14eb719ec38b6eb5b821c"], "id":1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_getFilterLogs", "params":["0x10ff0bfbedb01f0dbd4106d14eb719ec38b6eb5b821c"], "id":1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newblockfilter-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newblockfilter-request.mdx new file mode 100644 index 00000000000..ab2354d5d2a --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newblockfilter-request.mdx @@ -0,0 +1,23 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_newBlockFilter", "params":[], "id":1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method": "eth_newBlockFilter", "params":[], "id":1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newfilter-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newfilter-request.mdx new file mode 100644 index 00000000000..8b0656079e8 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newfilter-request.mdx @@ -0,0 +1,23 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc" : "2.0", "method": "eth_newFilter", "params": [{"topics": ["0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef"]}], "id":1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc" :"2.0", "method": "eth_newFilter", "params": [{"topics": ["0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef"]}], "id":1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newpendingtransactionfilter-description.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newpendingtransactionfilter-description.mdx new file mode 100644 index 00000000000..1c259a424d7 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newpendingtransactionfilter-description.mdx @@ -0,0 +1,2 @@ +Creates a filter to retrieve new pending transaction hashes. To poll for new pending transactions, use +[`eth_getFilterChanges`](./eth_getfilterchanges.mdx). \ No newline at end of file diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newpendingtransactionfilter-example.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newpendingtransactionfilter-example.mdx new file mode 100644 index 00000000000..9f7546de129 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newpendingtransactionfilter-example.mdx @@ -0,0 +1,2 @@ +Replace `YOUR-API-KEY` with an API key from your [Infura dashboard](https://infura.io/dashboard). + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newpendingtransactionfilter-parameters.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newpendingtransactionfilter-parameters.mdx new file mode 100644 index 00000000000..b0047fa49f0 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newpendingtransactionfilter-parameters.mdx @@ -0,0 +1 @@ +None diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newpendingtransactionfilter-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newpendingtransactionfilter-request.mdx new file mode 100644 index 00000000000..643d6c1374a --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newpendingtransactionfilter-request.mdx @@ -0,0 +1,22 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "newPendingTransactionFilter", "params": [], "id": 1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "method":"newPendingTransactionFilter", "params": [], "id": 1}' +``` + + + \ No newline at end of file diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newpendingtransactionfilter-response.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newpendingtransactionfilter-response.mdx new file mode 100644 index 00000000000..c7ed47d5a6a --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newpendingtransactionfilter-response.mdx @@ -0,0 +1,17 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```json +{ + "jsonrpc": "2.0", + "id": 1, + "result": "0x443d6a77c4964707a8554c92f7e4debd" +} +``` + + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newpendingtransactionfilter-returns.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newpendingtransactionfilter-returns.mdx new file mode 100644 index 00000000000..bb9337e06b0 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_newpendingtransactionfilter-returns.mdx @@ -0,0 +1,2 @@ +A filter ID that can be used to call [`eth_getFilterChanges`](./eth_getfilterchanges.mdx). + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_uninstallfilter-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_uninstallfilter-request.mdx new file mode 100644 index 00000000000..1e7e9abeb55 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/_eth_uninstallfilter-request.mdx @@ -0,0 +1,23 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc":"2.0","method":"eth_uninstallFilter","params":["0x10ff0bfba9472c87932c56632eef8f5cc70910e8e71d"],"id":1}' +``` + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc":"2.0","method":"eth_uninstallFilter","params":["0x10ff0bfba9472c87932c56632eef8f5cc70910e8e71d"],"id":1}' +``` + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/eth_getfilterchanges.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/eth_getfilterchanges.mdx new file mode 100644 index 00000000000..1c2db1bbfd2 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/eth_getfilterchanges.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getFilterChanges" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/filter-methods/_eth_getfilterchanges-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/filter-methods/_eth_getfilterchanges-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/filter-methods/_eth_getfilterchanges-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/filter-methods/_eth_getfilterchanges-example.mdx"; + + + +### Request + +import Request from "./_eth_getfilterchanges-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/filter-methods/_eth_getfilterchanges-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/eth_getfilterlogs.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/eth_getfilterlogs.mdx new file mode 100644 index 00000000000..34175570f83 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/eth_getfilterlogs.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_getFilterLogs" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/filter-methods/_eth_getfilterlogs-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/filter-methods/_eth_getfilterlogs-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/filter-methods/_eth_getfilterlogs-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/filter-methods/_eth_getfilterlogs-example.mdx"; + + + +### Request + +import Request from "./_eth_getfilterlogs-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/filter-methods/_eth_getfilterlogs-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/eth_newblockfilter.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/eth_newblockfilter.mdx new file mode 100644 index 00000000000..f0a2da610bc --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/eth_newblockfilter.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_newBlockFilter" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/filter-methods/_eth_newblockfilter-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/filter-methods/_eth_newblockfilter-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/filter-methods/_eth_newblockfilter-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/filter-methods/_eth_newblockfilter-example.mdx"; + + + +### Request + +import Request from "./_eth_newblockfilter-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/filter-methods/_eth_newblockfilter-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/eth_newfilter.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/eth_newfilter.mdx new file mode 100644 index 00000000000..40355694f3e --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/eth_newfilter.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_newFilter" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/filter-methods/_eth_newfilter-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/filter-methods/_eth_newfilter-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/filter-methods/_eth_newfilter-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/filter-methods/_eth_newfilter-example.mdx"; + + + +### Request + +import Request from "./_eth_newfilter-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/filter-methods/_eth_newfilter-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/eth_newpendingtransactionfilter.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/eth_newpendingtransactionfilter.mdx new file mode 100644 index 00000000000..e499f4971d6 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/eth_newpendingtransactionfilter.mdx @@ -0,0 +1,41 @@ +--- +title: "eth_newPendingTransactionFilter" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "./_eth_newpendingtransactionfilter-description.mdx"; + + + +## Parameters + +import Params from "./_eth_newpendingtransactionfilter-parameters.mdx"; + + + +## Returns + +import Returns from "./_eth_newpendingtransactionfilter-returns.mdx"; + + + +## Example + +import Example from "./_eth_newpendingtransactionfilter-example.mdx"; + + + +### Request + +import Request from "./_eth_newpendingtransactionfilter-request.mdx"; + + + +### Response + +import Response from "./_eth_newpendingtransactionfilter-response.mdx"; + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/eth_uninstallfilter.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/eth_uninstallfilter.mdx new file mode 100644 index 00000000000..ef2597682d9 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/eth_uninstallfilter.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_uninstallFilter" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/filter-methods/_eth_uninstallfilter-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/filter-methods/_eth_uninstallfilter-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/filter-methods/_eth_uninstallfilter-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/filter-methods/_eth_uninstallfilter-example.mdx"; + + + +### Request + +import Request from "./_eth_uninstallfilter-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/filter-methods/_eth_uninstallfilter-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/index.md b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/index.md new file mode 100644 index 00000000000..6b93b3a83dd --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/filter-methods/index.md @@ -0,0 +1,9 @@ +--- +title: "Filter methods" +--- + +# Filter Methods + +Infura supports the following filter methods over both HTTP and WebSocket. In both cases, the filter IDs can be shared by any connection using the same API key. + +Filters that are not polled using [`eth_getFilterChanges`](./eth_getfilterchanges.mdx) will be automatically expired after fifteen minutes of inactivity. diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/index.md b/services/reference/bnb-smart-chain/json-rpc-methods/index.md new file mode 100644 index 00000000000..5dabdba3cae --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/index.md @@ -0,0 +1,12 @@ +# JSON-RPC methods + +The standard Ethereum methods documented here are supported by Infura on the BNB Smart Chain (BSC) network. + +Currently, only near head requests (the last 128 blocks) are supported in the +BSC service. Archive requests are not currently supported. + +:::info + +WebSockets are also supported on the BSC network and can be used to set up bidirectional stateful [subscriptions](../../ethereum/json-rpc-methods/subscription-methods/index.md). + +::: diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/net_listening.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/net_listening.mdx new file mode 100644 index 00000000000..2c1fb3481b5 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/net_listening.mdx @@ -0,0 +1,40 @@ +--- +title: "net_listening" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_net_listening-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_net_listening-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_net_listening-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_net_listening-example.mdx"; + + + +### Request + +import Request from "./_net_listening-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_net_listening-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/net_peercount.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/net_peercount.mdx new file mode 100644 index 00000000000..c15460a96e3 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/net_peercount.mdx @@ -0,0 +1,40 @@ +--- +title: "net_peerCount" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_net_peercount-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_net_peercount-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_net_peercount-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_net_peercount-example.mdx"; + + + +### Request + +import Request from "./_net_peercount-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_net_peercount-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/net_version.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/net_version.mdx new file mode 100644 index 00000000000..b594ac81c6e --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/net_version.mdx @@ -0,0 +1,40 @@ +--- +title: "net_version" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_net_version-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_net_version-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_net_version-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_net_version-example.mdx"; + + + +### Request + +import Request from "./_net_version-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_net_version-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/subscription-methods/_eth_subscribe-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/subscription-methods/_eth_subscribe-request.mdx new file mode 100644 index 00000000000..0760ab8d844 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/subscription-methods/_eth_subscribe-request.mdx @@ -0,0 +1,28 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +wscat -c wss://linea-sepolia.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "id": 1, "method": "eth_subscribe", "params": ["newHeads"]}' +``` + + + + +```bash +wscat -c wss://linea-sepolia.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "id": 1, "method": "eth_subscribe", "params": ["logs", {"address": "0x8320fe7702b96808f7bbc0d4a888ed1468216cfd", "topics":["0xd78a0cb8bb633d06981248b816e7bd33c2a35a6089241d099fa519e361cab902"]}]}' +``` + + + + + +```bash +wscat -c wss://linea-sepolia.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "id": 1, "method": "eth_subscribe", "params": ["newPendingTransactions"]}' +``` + + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/subscription-methods/_eth_unsubscribe-request.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/subscription-methods/_eth_unsubscribe-request.mdx new file mode 100644 index 00000000000..88e848c9e10 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/subscription-methods/_eth_unsubscribe-request.mdx @@ -0,0 +1,14 @@ +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + + + + +```bash +wscat -c wss://bsc-mainnet.infura.io/ws/v3/YOUR-API-KEY -x '{"jsonrpc": "2.0", "id": 1, "method": "eth_unsubscribe", "params": ["0x9cef478923ff08bf67fde6c64013158d"]}' +``` + + + + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/subscription-methods/eth_subscribe.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/subscription-methods/eth_subscribe.mdx new file mode 100644 index 00000000000..ed34706f365 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/subscription-methods/eth_subscribe.mdx @@ -0,0 +1,44 @@ +--- +title: "eth_subscribe" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/subscription-methods/_eth_subscribe-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/subscription-methods/_eth_subscribe-parameters.mdx"; + + + +:::note +The `newPendingTransactions` event is only available on Linea Sepolia. +::: + +## Returns + +import Returns from "/services/reference/_partials/subscription-methods/_eth_subscribe-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/subscription-methods/_eth_subscribe-example.mdx"; + + + +### Request + +import Request from "./_eth_subscribe-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/subscription-methods/_eth_subscribe-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/subscription-methods/eth_unsubscribe.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/subscription-methods/eth_unsubscribe.mdx new file mode 100644 index 00000000000..fd4aedad7ad --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/subscription-methods/eth_unsubscribe.mdx @@ -0,0 +1,40 @@ +--- +title: "eth_unsubscribe" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/subscription-methods/_eth_unsubscribe-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/subscription-methods/_eth_unsubscribe-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/subscription-methods/_eth_unsubscribe-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/subscription-methods/_eth_unsubscribe-example.mdx"; + + + +### Request + +import Request from "./_eth_unsubscribe-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/subscription-methods/_eth_unsubscribe-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/subscription-methods/index.md b/services/reference/bnb-smart-chain/json-rpc-methods/subscription-methods/index.md new file mode 100644 index 00000000000..dc5adeaf968 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/subscription-methods/index.md @@ -0,0 +1,19 @@ +--- +title: "Subscription methods" +--- + +# Subscription methods + +Subscription methods are available for [WebSocket](../../../../concepts/websockets.md) connections only, and allow you to wait for events instead of polling for them. For example, dapps can subscribe to logs and receive notifications when a specific event occurs. + +The following subscription methods are available: + +- [`eth_subscribe`](./eth_subscribe.mdx) - Create a subscription to a particular event +- [`eth_unsubscribe`](./eth_unsubscribe.mdx) - Cancel an active subscription + +:::info + +We recommend you use the WSS protocol to set up bidirectional stateful subscriptions. Stateless HTTP WebSockets are also +supported. + +::: diff --git a/services/reference/bnb-smart-chain/json-rpc-methods/web3_clientversion.mdx b/services/reference/bnb-smart-chain/json-rpc-methods/web3_clientversion.mdx new file mode 100644 index 00000000000..0576523fc98 --- /dev/null +++ b/services/reference/bnb-smart-chain/json-rpc-methods/web3_clientversion.mdx @@ -0,0 +1,40 @@ +--- +title: "web3_clientVersion" +--- + +import Tabs from "@theme/Tabs" +import TabItem from "@theme/TabItem" + +import Description from "/services/reference/_partials/_web3_clientversion-description.mdx"; + + + +## Parameters + +import Params from "/services/reference/_partials/_web3_clientversion-parameters.mdx"; + + + +## Returns + +import Returns from "/services/reference/_partials/_web3_clientversion-returns.mdx"; + + + +## Example + +import Example from "/services/reference/_partials/_web3_clientversion-example.mdx"; + + + +### Request + +import Request from "./_web3_clientversion-request.mdx"; + + + +### Response + +import Response from "/services/reference/_partials/_web3_clientversion-response.mdx"; + + diff --git a/services/reference/bnb-smart-chain/quickstart.md b/services/reference/bnb-smart-chain/quickstart.md new file mode 100644 index 00000000000..95782c19bf1 --- /dev/null +++ b/services/reference/bnb-smart-chain/quickstart.md @@ -0,0 +1,198 @@ +--- +description: BNB Smart Chain quickstart guide +sidebar_position: 2 +--- + +import Banner from "@site/src/components/Banner" + +# Quickstart + +This quickstart guide will help you set up and make calls on the BNB Smart Chain network using the Infura endpoints. + + +Don't have an Infura account? Sign up for our free plan and start using the BNB Smart Chain network! + + +## Prerequisites + +Ensure you have an [API key](../../../developer-tools/dashboard/get-started/create-api) with the BNB Smart Chain networked enabled. + +## Make calls + +### cURL + +Run the following command in your terminal. Replace `YOUR-API-KEY` with your actual Infura API key. + +```bash +curl https://bsc-mainnet.infura.io/v3/YOUR-API-KEY \ + -X POST \ + -H "Content-Type: application/json" \ + -d '{"jsonrpc": "2.0", "method": "eth_blockNumber", "params": [], "id": 1}' +``` + +### Node (JavaScript) + +In these examples, you'll use [npm](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm) as your package manager. + +#### Node Fetch + +1. In your project folder, install the Node Fetch package using npm: + + ```bash + npm i node-fetch + `````` + +1. Create your Javascript file and copy the following code: + + Replace `YOUR-API-KEY` with your actual Infura API key. + + ```javascript title="index.js" + import fetch from "node-fetch"; + + fetch("https://bsc-mainnet.infura.io/v3/YOUR-API-KEY", { + method: "POST", + headers: { + "Content-Type": "application/json" + }, + body: JSON.stringify({ + jsonrpc: "2.0", + method: "eth_blockNumber", + params: [], + id: 1 + }) + }) + .then(response => + response.json() + ) + .then(data => { + console.log(data); + }) + .catch(error => { + console.error(error); + }); + ``` + +1. Run the code using the following command: + + ```bash + node index.js + ``` + +#### Axios + +1. In your project folder, install the Axios package using npm: + + ```bash + npm i axios + `````` + +1. Create your Javascript file and copy the following code: + + Replace `YOUR-API-KEY` with your actual Infura API key. + + ```javascript title="index.js" + const axios = require("axios"); + + axios.post("https://bsc-mainnet.infura.io/v3/YOUR-API-KEY", { + jsonrpc: "2.0", + method: "eth_blockNumber", + params: [], + id: 1 + }) + .then(response => { + console.log(response.data); + }) + .catch(error => { + console.error(error); + }); + ``` + +1. Run the code using the following command: + + ```bash + node index.js + ``` + +#### Ethers + +1. In your project folder, install the ethers package using npm: + + ```bash + npm install ethers + `````` + +1. Create your Javascript file and copy the following code: + + Replace `YOUR-API-KEY` with your actual Infura API key. + + ```javascript title="index.js" + const ethers = require("ethers"); + + const provider = new ethers.providers.JsonRpcProvider("https://bsc-mainnet.infura.io/v3/YOUR-API-KEY"); + + provider.getBlockNumber() + .then(blockNumber => { + console.log(blockNumber); + }) + .catch(error => { + console.error(error); + }); + ``` + +1. Run the code using the following command: + + ```bash + node index.js + ``` + +### Python + +1. In your project folder, install the `requests` library: + + ```bash + pip install requests + `````` + +1. Create your Python file and copy the following code: + + Replace `YOUR-API-KEY` with your actual Infura API key. + + ```python title="index.py" + import requests + import json + + url = "https://bsc-mainnet.infura.io/v3/YOUR-API-KEY" + + payload = { + "jsonrpc": "2.0", + "method": "eth_blockNumber", + "params": [], + "id": 1 + } + + headers = {"content-type": "application/json"} + + response = requests.post(url, data=json.dumps(payload), headers=headers).json() + + print(response) + ``` + +1. Run the code using the following command: + + ```bash + python index.py + ``` + +## Next steps + +Now that you have successfully made a call to the BNB Smart Chain network, you can explore more functionalities and APIs. Here are some suggestions: + +- **Explore other BNB Smart Chain APIs**: Infura supports a wide range of APIs. You can find more information in the +[JSON-RPC API method documentation](json-rpc-methods/index.md). + +- **Try out different networks**: Infura supports multiple networks including Ethereum, Linea, Polygon, Optimism, and more. + +- **Monitor your usage**: Keep an eye on your usage on the [Infura dashboard](../../../../developer-tools/dashboard/how-to/dashboard-stats/) to ensure you're not hitting your rate limits. + +Remember, the Infura community is here to help. If you have any questions or run into any issues, check out the +[Infura community](https://community.infura.io/) for help and answers to common questions. diff --git a/src/lib/data.js b/src/lib/data.js index e9120537192..8660085a377 100644 --- a/src/lib/data.js +++ b/src/lib/data.js @@ -60,6 +60,11 @@ export const NETWORK_LINKS = [ href: "/services/reference/blast", logo: `${LOGO_PATH}/logo-blast.svg`, }, + { + name: "BNB Smart Chain", + href: "/services/reference/bnb-smart-chain", + logo: `${LOGO_PATH}/logo-bnb.svg`, + }, { name: "Celo", href: "/services/reference/celo",